(1) Field of the Invention
The present invention relates to an image object content generation device, and more specifically relates to a padding processing for padding outside of an image object.
(2) Description of the Prior Art
MPEG (Moving Picture Coding Experts Group)-4 has attracted attention as an image compression method suitable for a mobile terminal or Internet that has dramatically developed in these years, as well as being suitable for conventionally storing media or digital broadcasting. MPEG-4 is an object-based image coding method, and one of the important features thereof is to resolve an image signal into that of a background and that of a component part (an object), such as a figure and a building, so as to compress and extend the image data per object. As an application of this method, there are needs of enlarging and reducing a screen size, that is, the needs for displaying an image taken by a home video camera in a small-sized liquid crystal display panel, such as a mobile phone, for example. There are also needs of changing a size of image content data, such as a figure image, into an arbitrary size, that is, the needs for importing a figure image separately taken on a blue background into a pre-taken background so as to composite both.
FIG. 1A is a diagram showing one block of Nxc3x97N pixels (N is a positive integer number) including a boundary between an object and a background when an image including an object and a background is scanned in the direction of an arrow. FIG. 1B is a graph showing a change of a pixel value (a brightness value, for example) of an image signal when the image in the block as shown in FIG. 1A is scanned in the direction x. In these figures, a horizontal axis indicates a location in the direction x, and a vertical axis indicates a pixel value at that location. And pixel values of an object pixel and a background pixel are indicated as digital values showing a gray scale in the range of 0xe2x89xa6Yxe2x89xa6255. An enlarged boundary portion of an image actually taken by using a CCD (Charge Coupled Device) or the like is the image as shown in the right part of FIG. 1A, where an image signal of a background is mixed into an object portion or that of an object is mixed into a background portion. As a result, if a static image comprising an object and a background as shown in FIG. 1A is scanned in the direction of the arrow, the image signal in the object (0xe2x89xa6x less than x0) is almost constant. On the contrary, the frequencies of the image signal become high around the boundary x0 between an object and a background, and they gradually turn to be constant the further they are from the boundary portion, as shown in FIG. 1B.
If an image block cut out from a frame includes an object pixel and a background pixel as the block shown in the right part of FIG. 1A does, when image data is compressed per object as a unit in MPEG-4, the image signal of the block includes high frequency components as shown in FIG. 1B and is not suitable for shape-adaptive discrete cosine transform (SA-DCT). Therefore, a padding processing needs to be performed in MPEG-4 for removing high frequency components of the image signal before performing the shape-adaptive discrete cosine transform. Padding processing is a processing for removing high frequency components by supplying an alternate pixel value to a background pixel adjacent to an object pixel (i.e., by padding a background pixel with an alternate pixel value).
As a prior art padding processing device, Japanese Laid-Open Patent Application H10-210470 Gazette discloses an example thereof, and this processing will be explained as follows based on FIG. 2.
FIG. 2 is a block diagram showing a structure of a conventional padding processing device disclosed in Japanese Laid-Open Patent Application H10-210470 Gazette. The padding processing device comprises a boundary block detection unit 100, a block scanning unit 210, a block compensation unit 220 and SA-DCT unit 300. The boundary block detection unit 100 scans plural image blocks of the same size of Nxc3x97N pixels (N is a positive integer number) including an object pixel and a background pixel and detects a background pixel intervening between object pixels on the identical line or row in the image block (a padding pixel). The block scanning unit 210 calculates an alternate pixel value by using a pixel value of an object pixel. The block compensation unit 220 supplies the alternate pixel value to the padding pixel and generates a padded image block. Thereby, in the compensated object area, the padding pixel that is a background pixel intervening between object pixels is padded with the alternate pixel value, and as a result, high frequency components in the boundary portion are removed. In this way, by performing a padding processing in the block compensation unit 220, the SA-DCT unit 300 can perform appropriate shape-adaptive discrete cosine transform of the input image signal of the object area and the background area including an object pixel and a background pixel, respectively.
However, since the conventional padding processing device just replaces a pixel value of a padding pixel with an alternate pixel value, there is a high possibility that quality of a generated image is deteriorated. Therefore, if a size of content image cut out from an input image is changed into a certain size, for example, it is difficult to generate it as high grade pixel data. Also, there are problems such that a larger memory capacity is required, a larger circuit scale is required, more electric power is consumed, and processing speed is reduced for realizing the padding processing without deteriorating the grade of the cutout object image.
It is accordingly a first object of the present invention, in the light of the above-mentioned conventional problems, to provide a padding device that can perform a padding processing without deteriorating a grade of an object image, and an image object content generation device that can generate high quality image object content by such a padding processing.
Also, the second object of the present invention is to provide a padding device and an image object content generation device that can be realized in a small circuit scale and perform high speed processing.
The above-mentioned first object may be achieved by an image object content generation device of the present invention that comprises: a key generation unit operable to generate a key that is a reference to distinguish an object pixel from a background pixel per pixel of an inputted image signal; a frame size changing unit operable to change a frame size of the image signal; a low frequency component passing unit operable to remove high frequency components of the image signal which was processed in the frame size changing unit; a pixel compensation unit operable to perform a padding processing, according to Low Pass Extrapolation padding algorithm, to the image signal which was processed in the low frequency component passing unit based on the key generated by the key generation unit; and a pixel selecting unit operable to select one of the image signal which was processed in the low frequency component passing unit and the image signal which was processed in the pixel compensation unit.
As described above, in the image object content generation device, the key generation unit generates a key that is a reference to distinguish an object pixel from a background pixel per pixel of an inputted image signal. The frame size changing unit changes a frame size of the image signal. The low frequency component passing unit removes high frequency components of the image signal which was processed in the frame size changing unit. The pixel compensation unit performs a padding processing to the image signal which was processed in the low frequency component passing unit by using Low Pass Extrapolation padding algorithm. The pixel selecting unit selects one of the image signal which was processed in the low frequency component passing unit and the image signal which was processed in the pixel compensation unit.
That is, according to this image object content generation device, the pixel compensation unit performs a padding processing using Low Pass Extrapolation padding algorithm. Therefore, since not only an alternate pixel value is given to a padding pixel, but the filtering processing is performed after that, more careful padding processing in which a pixel value of an adjacent pixel is reflected is performed. As a result, the image object content generation device can generate a high quality image object content.
Also, the above-mentioned second object may be achieved by an image object content generation device of the present invention, wherein the pixel compensation unit further includes: a buffer memory that stores a value of an image signal and a key value of each pixel which is sequentially inputted; an alternate pixel value generation unit that generates an alternate pixel value of the image signal of the object pixel based on the key value of each pixel which is sequentially inputted; a padding pixel location storing unit that stores information indicating a location of a padding pixel based on the key value of each pixel which is sequentially inputted; and a filtering unit that specifies a padding pixel by referring to the padding pixel location storing unit, and performs a filtering processing to the specified padding pixel by using the alternate pixel value and the value of the image signal in the buffer memory.
Thereby, information indicating a location of a padding pixel is stored in the padding pixel location storing unit, and according to the information, the filtering processing is performed by using an alternate pixel value. Therefore, a useless step just for replacing a pixel value of a padding pixel with an alternate pixel value is bypassed, and the padding processing in which replacement and filtering processing are integrated is executed. As a result, an intermediate buffer memory for storing a condition in which a pixel value of a padding pixel is just replaced with an alternate pixel value is not necessary, and a processing of repeating reading-out the alternate pixel value from the buffer memory is not necessary as well, thereby a circuit scale is reduced and processing speed is improved.
Note that the present invention can be embodied as an all-purpose padding device comprising only the function of the pixel compensation unit that is a distinctive constituent element of the image object content generation device (that is a padding device that performs a padding processing for padding outside of an image object). In addition, the present invention can be embodied as an image object content generation method and a padding method of which processing steps are distinctive constituent elements of the image object content generation device and the padding device, or as a program for making a computer execute the steps. And it goes without saying that the program can be distributed via a memory medium readable by a computer, such as a CD-ROM, and a transmission medium, such as a communication path.